﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Security.Cryptography;
using System.Security.RightsManagement;
using System.Text;
using System.Threading.Tasks;
using System.Windows;
using Caliburn.Micro;
using TestWpfCaliburn.Views;

namespace TestWpfCaliburn;

public class ShellViewModel
{
    public ShellViewModel(IWindowManager windowManager)
    {
        this.windowManager = windowManager;
        var dQuery = Enumerable.Empty<EmptyChartData>();
        DataItems = new(dQuery);
    }

    private readonly IWindowManager windowManager;

    public string TabName { get; set; } = "DEFECT_VALUE_COUNT";

    public BindableCollection<EmptyChartData> DataItems { get; set; } = new();

    public void ShowChild()
    {
        _ = windowManager.ShowDialogAsync(this);
    }

    public void ShowDynamicTable()
    {
        var screen = new DynamicTableViewModel();
        _ = windowManager.ShowDialogAsync(screen);
    }

    public void ShowDogs()
    {
        var screen = new DogManagerViewModel();
        _ = windowManager.ShowDialogAsync(screen);
    }
}

public record EmptyChartData;

public record IntChartData(int Value) : EmptyChartData;

public record StringChartData(string Value) : EmptyChartData;